package com.xixi.core.rpc.fault.retry;

import com.xixi.core.rpc.model.RpcResponse;

import java.util.concurrent.Callable;

/**
 * @author: zxh
 * @date: 2024/8/27 15:22
 * @description: 重试策略
 */
public interface RetryStrategy {

	/**
	 * 重试
	 * @author zxh
	 * @param callable 任务
	 * @return 返回请求结果
	 * @throws Exception
	 */
	RpcResponse doRetry(Callable<RpcResponse> callable) throws Exception;
}
